import json
from django.shortcuts import render
from django.http import HttpResponse
from .testOfprobiotics import *
# Create your views here.


def useProbiotics(request):
    if request.method == 'POST':
        data = json.loads(request.read())
        result = runProbiotics(data['seq'])
        return HttpResponse(result)
    elif request.method == 'GET':
        return render(request, 'index.html')



def useHome(request):
    return render(request,'home.html')
